package com.ruoyi.system.api;

import com.ruoyi.common.core.constant.ServiceNameConstants;
import com.ruoyi.common.core.web.domain.AjaxResult;
import com.ruoyi.common.core.web.page.TableDataInfo;

import com.ruoyi.system.api.domain.MailSendLog;
import com.ruoyi.system.api.factory.MailServerClientFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

/**
 * @
 */
@FeignClient(contextId = "MailServerClient", value = ServiceNameConstants.MAIL_SERVER, fallbackFactory = MailServerClientFallbackFactory.class)
public interface MailServerClient {


    @PutMapping("/mailServer")
    public AjaxResult edit(@Validated @RequestBody MailSendLog mailSendLog);

    @PostMapping("/mailServer")
    public AjaxResult add(@Validated @RequestBody MailSendLog mailSendLog);

    @GetMapping("/mailServer/list/{status}/")
    public TableDataInfo list(@PathVariable("status") Integer status);

}
